new Vue({
    el: "#app",
    data() {
        return {
            //用户信息
            userinfo:{
                userName:"",
                userPhone:"",
                originFullName:"",
            },
        }
    },
    created() {
        var that = this;
        that.queryUserInfoDetail();
    },
    methods: {
        /*获取用户信息详情*/
        queryUserInfoDetail(){
            var that = this;
            $.ajax({
                type: "GET",//方法类型
                dataType: "json",//预期服务器返回的数据类型
                url:"/user/center/userDetailInfo",
                data:{},
                success: function (res) {
                    if(res.code == 0){
                        // 设置信息
                        console.log(res);
                        that.userinfo.userName = res.data.userName;
                        that.userinfo.userPhone = res.data.userPhone
                        that.userinfo.originFullName = res.data.originFullName;
                        that.userinfo.userOrigins = res.data.userOrigins;
                    }else {
                        // 获取失败,弹出信息
                        wapAlert(res.msg);
                    }
                },
                error : function() {

                }
            });
        },
        home:function () {
            
        },
        back:function () {
            window.location.href="/cloud/user/center/index";
        }
    }
})
